<template>
	<div class="app">
		<button @click="testShowDialog">显示模态框</button>
	</div>
</template>

<script>
// 先引入js中显示对话框函数
import { showDialog } from './components/mydialog.js';

export default {
	name: 'app',
	methods: {
		testShowDialog() {
			showDialog(
				'提示：少时诵诗书所所所所所所所所所所所所所所所所所所所所所所所所所所所所所所所',
				require('./assets/1.png'),
				() => {
					console.log('点击了确定');
				},
				() => {
					console.log('点击了取消');
				}
			);
		},
	},
};
</script>